define(function() {
	function Exception(text, error, source, file, previous) {
		var scripts = document.getElementsByTagName( 'script' );
		 
		this.type = "Base Exception";
		this.error = (text) ? text : 'Undefined Exception';
		this.line = (error) ? error : '';
		this.source = (source) ? source : '';
		this.file = (file) ? file : scripts[ scripts.length - 1 ];
		this.previous = (previous) ? previous : {};
	};
	
	return Exception;
});